<template>
  <div>
    <el-form ref="elForm" :model="formData" label-width="80px">
      <el-form-item label="商品详情" prop="categoryId">
        <Editor :height="800" v-model="formData.productHtml" />
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
  export default {
    name: 'productDetali',
    props: {
      value: [Object]
    },
    data() {
      return {
        formData: {
          productHtml: ""
        }
      };
    },

    mounted() {

    },
    watch: {
      value: {
        handler(val) {
          console.log(val)
          if (val) {
            this.formData = val
          }
        },
        deep: true,
        immediate: true
      }
    },
    methods: {
      reset() {
        this.formData.productHtml = ""
      }
    },
  };
</script>
